AddrToString

Err:=AddrToString(Target;ATLocation;Name;Port)

Converts a target address returned by MakeAddress, SelectAddress, or GetReturnAddr into strings which may be saved between sessions. ATLocation describes the machine's network identity and will be a string something like 'Mike:PPCToolBox@*'. It will be an empty string if the program is running on your local machine. 'Name' is the actual name of the program. Port is a PPC Toolbox port ID (usually the creator ID followed by "ep01").

DisposeAddress

Err:=DisposeAddress(Target)

Disposes the target address handle that was previously allocated with MakeAddress, SelectAddress, or GetReturnAddr. This is assumed to be a handle to an address descriptor. Since this is passed to DisposHandle, the system may crash if this isn't a valid handle. Note that DisposeAddress is the same as the new low-level function DisposeDesc, but has been kept for compatibility with older versions.

MakeAddress

Err:=MakeAddress(Signature;Target)

Creates a target address from an application signature. The application must be running on the local system. You must not modify this value in any way and should call DisposeAddress when you're finished using this handle.

SelectAddress

Err:=SelectAddress(Prompt;Signature;Target)

Opens the PPC Browser window, which allows you to select a program on your system or on a remote system to send AppleEvents to. If prompt isn't an empty string, it will be used instead of the default "select a program to link to" message. If the signature is an empty string, all programs will be listed. Otherwise only programs matching that signature will be listed. If this function returns 0, a handle to an address descriptor will be allocated and placed into 'target'. You must not modify this value in any way and should call DisposeAddress when you're finished using this handle.

Example:
_________________________________________________________________
 if (SelectAddress("Select a copy of Hypercard:";"WILD";$Target)=0)
 
$err:=DoScript($Target;"Go To Stack 'my stack'")
 
$err:=DoScript($Target;"Go To Next Card")
 
$err:=DoScript($Target;"Print Card")
 
$err:=DisposeAddress($Target)
 end if
_________________________________________________________________

StringToAddr

Err:=StringToAddr(ATLocation;Name;Port;Target)

Creates a target ID from a set of strings describing it. This is the complementary function to AddrToString. ATLocation describes the machine's network identity (should be an empty string if the program is running on your local machine). Otherwise, it will be a string like 'name:PPCToolBox @ zone'. Name is the actual name of the program. Port is a PPC Toolbox port ID, which is the 4-letter creator ID (it’s actually the creator ID followed by “ep01”, but the creator ID alone is allowed).